import { ref, watch } from "vue";
import { PortalConfig } from "@/views/uniapp/portal/types/types";
import { useRoute } from "vue-router";
import { watchDebounced } from "@vueuse/core";
import { updatePortal } from "@/api/uniapp/portal";

export function usePortalConfigStore() {
  const portalConfig = ref<PortalConfig>({
    navList: [],
    tabBarList: [],
    bannerList: []
  });

  return {
    portalConfig
  };
}

export const allTabBarList = [
  {
    pagePath: "/pages/index/index",
    iconPath:
      "",
    text: "首页"
  },
  {
    pagePath: "/pages/home/index",
    iconPath:
      "",
    text: "工作台"
  },
  {
    pagePath: "/pages/form/index",
    iconPath:
      "",
    text: "表单"
  },
  {
    pagePath: "/pages/me/index",
    iconPath:
      "",
    text: "我的"
  }
];

export const portalConfigStore = usePortalConfigStore();
